<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
<title>Examples</title>
<link rel="stylesheet" href="../../../doc/src/boostbook.css" type="text/css">
<meta name="generator" content="DocBook XSL Stylesheets V1.76.1">
<link rel="home" href="../boost_asio.html" title="Boost.Asio">
<link rel="up" href="../boost_asio.html" title="Boost.Asio">
<link rel="prev" href="tutorial/tutdaytime7/src.html" title="Source listing for Daytime.7">
<link rel="next" href="reference.html" title="Reference">
</head>
<body bgcolor="white" text="black" link="#0000FF" vlink="#840084" alink="#0000FF">
<table cellpadding="2" width="100%"><tr>
<td valign="top"><img alt="Boost C++ Libraries" width="277" height="86" src="../../../boost.png"></td>
<td align="center"><a href="../../../index.html">Home</a></td>
<td align="center"><a href="../../../libs/libraries.htm">Libraries</a></td>
<td align="center"><a href="http://www.boost.org/users/people.html">People</a></td>
<td align="center"><a href="http://www.boost.org/users/faq.html">FAQ</a></td>
<td align="center"><a href="../../../more/index.htm">More</a></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="tutorial/tutdaytime7/src.html"><img src="../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_asio.html"><img src="../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../boost_asio.html"><img src="../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="reference.html"><img src="../../../doc/src/images/next.png" alt="Next"></a>
</div>
<div class="section">
<div class="titlepage"><div><div><h2 class="title" style="clear: both">
<a name="boost_asio.examples"></a><a class="link" href="examples.html" title="Examples">Examples</a>
</h2></div></div></div>
<h4>
<a name="boost_asio.examples.h0"></a>
      <span><a name="boost_asio.examples.allocation"></a></span><a class="link" href="examples.html#boost_asio.examples.allocation">Allocation</a>
    </h4>
<p>
      This example shows how to customise the allocation of memory associated with
      asynchronous operations.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
          <a href="example/allocation/server.cpp" target="_top">boost_asio/example/allocation/server.cpp</a>
        </li></ul></div>
<h4>
<a name="boost_asio.examples.h1"></a>
      <span><a name="boost_asio.examples.buffers"></a></span><a class="link" href="examples.html#boost_asio.examples.buffers">Buffers</a>
    </h4>
<p>
      This example demonstrates how to create reference counted buffers that can
      be used with socket read and write operations.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
          <a href="example/buffers/reference_counted.cpp" target="_top">boost_asio/example/buffers/reference_counted.cpp</a>
        </li></ul></div>
<h4>
<a name="boost_asio.examples.h2"></a>
      <span><a name="boost_asio.examples.chat"></a></span><a class="link" href="examples.html#boost_asio.examples.chat">Chat</a>
    </h4>
<p>
      This example implements a chat server and client. The programs use a custom
      protocol with a fixed length message header and variable length message body.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/chat/chat_message.hpp" target="_top">boost_asio/example/chat/chat_message.hpp</a>
        </li>
<li class="listitem">
          <a href="example/chat/chat_client.cpp" target="_top">boost_asio/example/chat/chat_client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/chat/chat_server.cpp" target="_top">boost_asio/example/chat/chat_server.cpp</a>
        </li>
</ul></div>
<p>
      The following POSIX-specific chat client demonstrates how to use the <a class="link" href="reference/posix__stream_descriptor.html" title="posix::stream_descriptor">posix::stream_descriptor</a>
      class to perform console input and output.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
          <a href="example/chat/posix_chat_client.cpp" target="_top">boost_asio/example/chat/posix_chat_client.cpp</a>
        </li></ul></div>
<h4>
<a name="boost_asio.examples.h3"></a>
      <span><a name="boost_asio.examples.echo"></a></span><a class="link" href="examples.html#boost_asio.examples.echo">Echo</a>
    </h4>
<p>
      A collection of simple clients and servers, showing the use of both synchronous
      and asynchronous operations.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/echo/async_tcp_echo_server.cpp" target="_top">boost_asio/example/echo/async_tcp_echo_server.cpp</a>
        </li>
<li class="listitem">
          <a href="example/echo/async_udp_echo_server.cpp" target="_top">boost_asio/example/echo/async_udp_echo_server.cpp</a>
        </li>
<li class="listitem">
          <a href="example/echo/blocking_tcp_echo_client.cpp" target="_top">boost_asio/example/echo/blocking_tcp_echo_client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/echo/blocking_tcp_echo_server.cpp" target="_top">boost_asio/example/echo/blocking_tcp_echo_server.cpp</a>
        </li>
<li class="listitem">
          <a href="example/echo/blocking_udp_echo_client.cpp" target="_top">boost_asio/example/echo/blocking_udp_echo_client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/echo/blocking_udp_echo_server.cpp" target="_top">boost_asio/example/echo/blocking_udp_echo_server.cpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h4"></a>
      <span><a name="boost_asio.examples.fork"></a></span><a class="link" href="examples.html#boost_asio.examples.fork">Fork</a>
    </h4>
<p>
      These POSIX-specific examples show how to use Boost.Asio in conjunction with
      the <code class="computeroutput"><span class="identifier">fork</span><span class="special">()</span></code>
      system call. The first example illustrates the steps required to start a daemon
      process:
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
          <a href="example/fork/daemon.cpp" target="_top">boost_asio/example/fork/daemon.cpp</a>
        </li></ul></div>
<p>
      The second example demonstrates how it is possible to fork a process from within
      a completion handler.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
          <a href="example/fork/process_per_connection.cpp" target="_top">boost_asio/example/fork/process_per_connection.cpp</a>
        </li></ul></div>
<h4>
<a name="boost_asio.examples.h5"></a>
      <span><a name="boost_asio.examples.http_client"></a></span><a class="link" href="examples.html#boost_asio.examples.http_client">HTTP
      Client</a>
    </h4>
<p>
      Example programs implementing simple HTTP 1.0 clients. These examples show
      how to use the <a class="link" href="reference/read_until.html" title="read_until">read_until</a>
      and <a class="link" href="reference/async_read_until.html" title="async_read_until">async_read_until</a>
      functions.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/http/client/sync_client.cpp" target="_top">boost_asio/example/http/client/sync_client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/client/async_client.cpp" target="_top">boost_asio/example/http/client/async_client.cpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h6"></a>
      <span><a name="boost_asio.examples.http_server"></a></span><a class="link" href="examples.html#boost_asio.examples.http_server">HTTP
      Server</a>
    </h4>
<p>
      This example illustrates the use of asio in a simple single-threaded server
      implementation of HTTP 1.0. It demonstrates how to perform a clean shutdown
      by cancelling all outstanding asynchronous operations.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/http/server/connection.cpp" target="_top">boost_asio/example/http/server/connection.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/connection.hpp" target="_top">boost_asio/example/http/server/connection.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/connection_manager.cpp" target="_top">boost_asio/example/http/server/connection_manager.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/connection_manager.hpp" target="_top">boost_asio/example/http/server/connection_manager.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/header.hpp" target="_top">boost_asio/example/http/server/header.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/main.cpp" target="_top">boost_asio/example/http/server/main.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/mime_types.cpp" target="_top">boost_asio/example/http/server/mime_types.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/mime_types.hpp" target="_top">boost_asio/example/http/server/mime_types.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/reply.cpp" target="_top">boost_asio/example/http/server/reply.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/reply.hpp" target="_top">boost_asio/example/http/server/reply.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/request.hpp" target="_top">boost_asio/example/http/server/request.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/request_handler.cpp" target="_top">boost_asio/example/http/server/request_handler.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/request_handler.hpp" target="_top">boost_asio/example/http/server/request_handler.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/request_parser.cpp" target="_top">boost_asio/example/http/server/request_parser.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/request_parser.hpp" target="_top">boost_asio/example/http/server/request_parser.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/server.cpp" target="_top">boost_asio/example/http/server/server.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server/server.hpp" target="_top">boost_asio/example/http/server/server.hpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h7"></a>
      <span><a name="boost_asio.examples.http_server_2"></a></span><a class="link" href="examples.html#boost_asio.examples.http_server_2">HTTP
      Server 2</a>
    </h4>
<p>
      An HTTP server using an io_service-per-CPU design.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/http/server2/connection.cpp" target="_top">boost_asio/example/http/server2/connection.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/connection.hpp" target="_top">boost_asio/example/http/server2/connection.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/header.hpp" target="_top">boost_asio/example/http/server2/header.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/io_service_pool.cpp" target="_top">boost_asio/example/http/server2/io_service_pool.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/io_service_pool.hpp" target="_top">boost_asio/example/http/server2/io_service_pool.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/main.cpp" target="_top">boost_asio/example/http/server2/main.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/mime_types.cpp" target="_top">boost_asio/example/http/server2/mime_types.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/mime_types.hpp" target="_top">boost_asio/example/http/server2/mime_types.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/reply.cpp" target="_top">boost_asio/example/http/server2/reply.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/reply.hpp" target="_top">boost_asio/example/http/server2/reply.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/request.hpp" target="_top">boost_asio/example/http/server2/request.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/request_handler.cpp" target="_top">boost_asio/example/http/server2/request_handler.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/request_handler.hpp" target="_top">boost_asio/example/http/server2/request_handler.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/request_parser.cpp" target="_top">boost_asio/example/http/server2/request_parser.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/request_parser.hpp" target="_top">boost_asio/example/http/server2/request_parser.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/server.cpp" target="_top">boost_asio/example/http/server2/server.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server2/server.hpp" target="_top">boost_asio/example/http/server2/server.hpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h8"></a>
      <span><a name="boost_asio.examples.http_server_3"></a></span><a class="link" href="examples.html#boost_asio.examples.http_server_3">HTTP
      Server 3</a>
    </h4>
<p>
      An HTTP server using a single io_service and a thread pool calling <code class="computeroutput"><span class="identifier">io_service</span><span class="special">::</span><span class="identifier">run</span><span class="special">()</span></code>.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/http/server3/connection.cpp" target="_top">boost_asio/example/http/server3/connection.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/connection.hpp" target="_top">boost_asio/example/http/server3/connection.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/header.hpp" target="_top">boost_asio/example/http/server3/header.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/main.cpp" target="_top">boost_asio/example/http/server3/main.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/mime_types.cpp" target="_top">boost_asio/example/http/server3/mime_types.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/mime_types.hpp" target="_top">boost_asio/example/http/server3/mime_types.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/reply.cpp" target="_top">boost_asio/example/http/server3/reply.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/reply.hpp" target="_top">boost_asio/example/http/server3/reply.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/request.hpp" target="_top">boost_asio/example/http/server3/request.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/request_handler.cpp" target="_top">boost_asio/example/http/server3/request_handler.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/request_handler.hpp" target="_top">boost_asio/example/http/server3/request_handler.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/request_parser.cpp" target="_top">boost_asio/example/http/server3/request_parser.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/request_parser.hpp" target="_top">boost_asio/example/http/server3/request_parser.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/server.cpp" target="_top">boost_asio/example/http/server3/server.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server3/server.hpp" target="_top">boost_asio/example/http/server3/server.hpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h9"></a>
      <span><a name="boost_asio.examples.http_server_4"></a></span><a class="link" href="examples.html#boost_asio.examples.http_server_4">HTTP
      Server 4</a>
    </h4>
<p>
      A single-threaded HTTP server implemented using stackless coroutines.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/http/server4/coroutine.hpp" target="_top">boost_asio/example/http/server4/coroutine.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/file_handler.cpp" target="_top">boost_asio/example/http/server4/file_handler.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/file_handler.hpp" target="_top">boost_asio/example/http/server4/file_handler.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/header.hpp" target="_top">boost_asio/example/http/server4/header.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/main.cpp" target="_top">boost_asio/example/http/server4/main.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/mime_types.cpp" target="_top">boost_asio/example/http/server4/mime_types.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/mime_types.hpp" target="_top">boost_asio/example/http/server4/mime_types.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/reply.cpp" target="_top">boost_asio/example/http/server4/reply.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/reply.hpp" target="_top">boost_asio/example/http/server4/reply.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/request.hpp" target="_top">boost_asio/example/http/server4/request.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/request_parser.cpp" target="_top">boost_asio/example/http/server4/request_parser.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/request_parser.hpp" target="_top">boost_asio/example/http/server4/request_parser.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/server.cpp" target="_top">boost_asio/example/http/server4/server.cpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/server.hpp" target="_top">boost_asio/example/http/server4/server.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/unyield.hpp" target="_top">boost_asio/example/http/server4/unyield.hpp</a>
        </li>
<li class="listitem">
          <a href="example/http/server4/yield.hpp" target="_top">boost_asio/example/http/server4/yield.hpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h10"></a>
      <span><a name="boost_asio.examples.icmp"></a></span><a class="link" href="examples.html#boost_asio.examples.icmp">ICMP</a>
    </h4>
<p>
      This example shows how to use raw sockets with ICMP to ping a remote host.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/icmp/ping.cpp" target="_top">boost_asio/example/icmp/ping.cpp</a>
        </li>
<li class="listitem">
          <a href="example/icmp/ipv4_header.hpp" target="_top">boost_asio/example/icmp/ipv4_header.hpp</a>
        </li>
<li class="listitem">
          <a href="example/icmp/icmp_header.hpp" target="_top">boost_asio/example/icmp/icmp_header.hpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h11"></a>
      <span><a name="boost_asio.examples.invocation"></a></span><a class="link" href="examples.html#boost_asio.examples.invocation">Invocation</a>
    </h4>
<p>
      This example shows how to customise handler invocation. Completion handlers
      are added to a priority queue rather than executed immediately.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
          <a href="example/invocation/prioritised_handlers.cpp" target="_top">boost_asio/example/invocation/prioritised_handlers.cpp</a>
        </li></ul></div>
<h4>
<a name="boost_asio.examples.h12"></a>
      <span><a name="boost_asio.examples.iostreams"></a></span><a class="link" href="examples.html#boost_asio.examples.iostreams">Iostreams</a>
    </h4>
<p>
      Two examples showing how to use <a class="link" href="reference/ip__tcp/iostream.html" title="ip::tcp::iostream">ip::tcp::iostream</a>.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/iostreams/daytime_client.cpp" target="_top">boost_asio/example/iostreams/daytime_client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/iostreams/daytime_server.cpp" target="_top">boost_asio/example/iostreams/daytime_server.cpp</a>
        </li>
<li class="listitem">
          <a href="example/iostreams/http_client.cpp" target="_top">boost_asio/example/iostreams/http_client.cpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h13"></a>
      <span><a name="boost_asio.examples.multicast"></a></span><a class="link" href="examples.html#boost_asio.examples.multicast">Multicast</a>
    </h4>
<p>
      An example showing the use of multicast to transmit packets to a group of subscribers.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/multicast/receiver.cpp" target="_top">boost_asio/example/multicast/receiver.cpp</a>
        </li>
<li class="listitem">
          <a href="example/multicast/sender.cpp" target="_top">boost_asio/example/multicast/sender.cpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h14"></a>
      <span><a name="boost_asio.examples.serialization"></a></span><a class="link" href="examples.html#boost_asio.examples.serialization">Serialization</a>
    </h4>
<p>
      This example shows how Boost.Serialization can be used with asio to encode
      and decode structures for transmission over a socket.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/serialization/client.cpp" target="_top">boost_asio/example/serialization/client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/serialization/connection.hpp" target="_top">boost_asio/example/serialization/connection.hpp</a>
        </li>
<li class="listitem">
          <a href="example/serialization/server.cpp" target="_top">boost_asio/example/serialization/server.cpp</a>
        </li>
<li class="listitem">
          <a href="example/serialization/stock.hpp" target="_top">boost_asio/example/serialization/stock.hpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h15"></a>
      <span><a name="boost_asio.examples.services"></a></span><a class="link" href="examples.html#boost_asio.examples.services">Services</a>
    </h4>
<p>
      This example demonstrates how to integrate custom functionality (in this case,
      for logging) into asio's <a class="link" href="reference/io_service.html" title="io_service">io_service</a>,
      and how to use a custom service with <a class="link" href="reference/basic_stream_socket.html" title="basic_stream_socket">basic_stream_socket&lt;&gt;</a>.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/services/basic_logger.hpp" target="_top">boost_asio/example/services/basic_logger.hpp</a>
        </li>
<li class="listitem">
          <a href="example/services/daytime_client.cpp" target="_top">boost_asio/example/services/daytime_client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/services/logger.hpp" target="_top">boost_asio/example/services/logger.hpp</a>
        </li>
<li class="listitem">
          <a href="example/services/logger_service.cpp" target="_top">boost_asio/example/services/logger_service.cpp</a>
        </li>
<li class="listitem">
          <a href="example/services/logger_service.hpp" target="_top">boost_asio/example/services/logger_service.hpp</a>
        </li>
<li class="listitem">
          <a href="example/services/stream_socket_service.hpp" target="_top">boost_asio/example/services/stream_socket_service.hpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h16"></a>
      <span><a name="boost_asio.examples.socks_4"></a></span><a class="link" href="examples.html#boost_asio.examples.socks_4">SOCKS
      4</a>
    </h4>
<p>
      Example client program implementing the SOCKS 4 protocol for communication
      via a proxy.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/socks4/sync_client.cpp" target="_top">boost_asio/example/socks4/sync_client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/socks4/socks4.hpp" target="_top">boost_asio/example/socks4/socks4.hpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h17"></a>
      <span><a name="boost_asio.examples.ssl"></a></span><a class="link" href="examples.html#boost_asio.examples.ssl">SSL</a>
    </h4>
<p>
      Example client and server programs showing the use of the <a class="link" href="reference/ssl__stream.html" title="ssl::stream">ssl::stream&lt;&gt;</a>
      template with asynchronous operations.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/ssl/client.cpp" target="_top">boost_asio/example/ssl/client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/ssl/server.cpp" target="_top">boost_asio/example/ssl/server.cpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h18"></a>
      <span><a name="boost_asio.examples.timeouts"></a></span><a class="link" href="examples.html#boost_asio.examples.timeouts">Timeouts</a>
    </h4>
<p>
      A collection of examples showing how to cancel long running asynchronous operations
      after a period of time.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/timeouts/async_tcp_client.cpp" target="_top">boost_asio/example/timeouts/async_tcp_client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/timeouts/blocking_tcp_client.cpp" target="_top">boost_asio/example/timeouts/blocking_tcp_client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/timeouts/blocking_udp_client.cpp" target="_top">boost_asio/example/timeouts/blocking_udp_client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/timeouts/server.cpp" target="_top">boost_asio/example/timeouts/server.cpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h19"></a>
      <span><a name="boost_asio.examples.timers"></a></span><a class="link" href="examples.html#boost_asio.examples.timers">Timers</a>
    </h4>
<p>
      Examples showing how to customise deadline_timer using different time types.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/timers/tick_count_timer.cpp" target="_top">boost_asio/example/timers/tick_count_timer.cpp</a>
        </li>
<li class="listitem">
          <a href="example/timers/time_t_timer.cpp" target="_top">boost_asio/example/timers/time_t_timer.cpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h20"></a>
      <span><a name="boost_asio.examples.porthopper"></a></span><a class="link" href="examples.html#boost_asio.examples.porthopper">Porthopper</a>
    </h4>
<p>
      Example illustrating mixed synchronous and asynchronous operations, and how
      to use Boost.Lambda with Boost.Asio.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/porthopper/protocol.hpp" target="_top">boost_asio/example/porthopper/protocol.hpp</a>
        </li>
<li class="listitem">
          <a href="example/porthopper/client.cpp" target="_top">boost_asio/example/porthopper/client.cpp</a>
        </li>
<li class="listitem">
          <a href="example/porthopper/server.cpp" target="_top">boost_asio/example/porthopper/server.cpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h21"></a>
      <span><a name="boost_asio.examples.nonblocking"></a></span><a class="link" href="examples.html#boost_asio.examples.nonblocking">Nonblocking</a>
    </h4>
<p>
      Example demonstrating reactor-style operations for integrating a third-party
      library that wants to perform the I/O operations itself.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
          <a href="example/nonblocking/third_party_lib.cpp" target="_top">boost_asio/example/nonblocking/third_party_lib.cpp</a>
        </li></ul></div>
<h4>
<a name="boost_asio.examples.h22"></a>
      <span><a name="boost_asio.examples.unix_domain_sockets"></a></span><a class="link" href="examples.html#boost_asio.examples.unix_domain_sockets">UNIX
      Domain Sockets</a>
    </h4>
<p>
      Examples showing how to use UNIX domain (local) sockets.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc">
<li class="listitem">
          <a href="example/local/connect_pair.cpp" target="_top">boost_asio/example/local/connect_pair.cpp</a>
        </li>
<li class="listitem">
          <a href="example/local/stream_server.cpp" target="_top">boost_asio/example/local/stream_server.cpp</a>
        </li>
<li class="listitem">
          <a href="example/local/stream_client.cpp" target="_top">boost_asio/example/local/stream_client.cpp</a>
        </li>
</ul></div>
<h4>
<a name="boost_asio.examples.h23"></a>
      <span><a name="boost_asio.examples.windows"></a></span><a class="link" href="examples.html#boost_asio.examples.windows">Windows</a>
    </h4>
<p>
      An example showing how to use the Windows-specific function <code class="computeroutput"><span class="identifier">TransmitFile</span></code>
      with Boost.Asio.
    </p>
<div class="itemizedlist"><ul class="itemizedlist" type="disc"><li class="listitem">
          <a href="example/windows/transmit_file.cpp" target="_top">boost_asio/example/windows/transmit_file.cpp</a>
        </li></ul></div>
</div>
<table xmlns:rev="http://www.cs.rpi.edu/~gregod/boost/tools/doc/revision" width="100%"><tr>
<td align="left"></td>
<td align="right"><div class="copyright-footer">Copyright &#169; 2003-2012 Christopher M. Kohlhoff<p>
        Distributed under the Boost Software License, Version 1.0. (See accompanying
        file LICENSE_1_0.txt or copy at <a href="http://www.boost.org/LICENSE_1_0.txt" target="_top">http://www.boost.org/LICENSE_1_0.txt</a>)
      </p>
</div></td>
</tr></table>
<hr>
<div class="spirit-nav">
<a accesskey="p" href="tutorial/tutdaytime7/src.html"><img src="../../../doc/src/images/prev.png" alt="Prev"></a><a accesskey="u" href="../boost_asio.html"><img src="../../../doc/src/images/up.png" alt="Up"></a><a accesskey="h" href="../boost_asio.html"><img src="../../../doc/src/images/home.png" alt="Home"></a><a accesskey="n" href="reference.html"><img src="../../../doc/src/images/next.png" alt="Next"></a>
</div>
</body>
</html>
